<?php
// 本类由系统自动生成，仅供测试用途
class IndexAction extends Action {
	function _initialize(){
		
			if(!isset($_SESSION['main_name'])){
				$this->redirect('Login/index', array(),1,'<script language="JavaScript">alert("请登录")</script>');
			}
		}
	
    public function index(){
    	
    	$this->display();
    }
    
	public function top(){
		
		$this->display();
	}
	
	public function menu(){
		$model=M('admin_user');
		$model->getByUsername($_SESSION['main_name']);
		$name=$model->username;
		$quanxian=$model->authority;
		if($quanxian==10){
				$quanxian_value="超级管理员";
			}elseif ($quanxian==9){
				$quanxian_value="管理员";
			}elseif ($quanxian==2){
				$quanxian_value="物流管理";
			}elseif ($quanxian==3){
				$quanxian_value="客服";
			}
		$this->assign('quanxian',$quanxian);
		$this->assign('quanxian_value',$quanxian_value);
		$this->assign('name',$name);
		$this->display();
	}
	
	public function ServerInfo(){
		
		$this->display();
	}
	
}